-
Notifications
You must be signed in to change notification settings - Fork 76
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update FENCE/FENCE.I decoding #138
Conversation
@@ -1487,24 +1487,23 @@ end : cam_array | |||
|
|||
endmodule // el2_dec_decode_ctl |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[verible-verilog-format] reported by reviewdog 🐶
endmodule // el2_dec_decode_ctl | |
endmodule // el2_dec_decode_ctl |
design/dec/el2_dec_decode_ctl.sv
Outdated
&i[4]) | (i[2]) | (i[6]) | (!i[30]&i[29]&!i[24]&!i[23]&i[22]&i[21] | ||
&i[20]&!i[5]&i[4]) | (!i[12]&!i[5]&i[4]); | ||
&i[4]) | (i[6]) | (!i[30]&i[29]&!i[24]&!i[23]&i[22]&i[21]&i[20]&!i[5] | ||
&i[4]) | (i[2]) | (!i[12]&!i[5]&i[4]); | ||
|
||
assign out.rs1 = (!i[13]&i[11]&!i[2]) | (!i[13]&i[10]&!i[2]) | (i[19]&i[13]&!i[2]) | ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[verible-verilog-format] reported by reviewdog 🐶
assign out.rs1 = (!i[13]&i[11]&!i[2]) | (!i[13]&i[10]&!i[2]) | (i[19]&i[13]&!i[2]) | ( | |
assign out.rs1 = (!i[13]&i[11]&!i[2]) | (!i[13]&i[10]&!i[2]) | (i[19]&i[13]&!i[2]) | ( |
design/dec/el2_dec_decode_ctl.sv
Outdated
@@ -1563,7 +1562,7 @@ assign out.sub = (i[30]&!i[14]&!i[12]&!i[6]&i[5]&i[4]&!i[2]) | (!i[29]&!i[25]&!i | |||
assign out.land = (!i[27]&!i[25]&i[14]&i[13]&i[12]&!i[6]&!i[2]) | (i[14]&i[13]&i[12] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[verible-verilog-format] reported by reviewdog 🐶
assign out.land = (!i[27]&!i[25]&i[14]&i[13]&i[12]&!i[6]&!i[2]) | (i[14]&i[13]&i[12] | |
assign out.land = (!i[27]&!i[25]&i[14]&i[13]&i[12]&!i[6]&!i[2]) | (i[14]&i[13]&i[12] |
design/dec/el2_dec_decode_ctl.sv
Outdated
@@ -1563,7 +1562,7 @@ assign out.sub = (i[30]&!i[14]&!i[12]&!i[6]&i[5]&i[4]&!i[2]) | (!i[29]&!i[25]&!i | |||
assign out.land = (!i[27]&!i[25]&i[14]&i[13]&i[12]&!i[6]&!i[2]) | (i[14]&i[13]&i[12] | |||
&!i[5]&!i[2]); | |||
|
|||
assign out.lor = (!i[6]&i[3]) | (!i[29]&!i[27]&!i[25]&i[14]&i[13]&!i[12]&!i[6]&!i[2]) | ( | |||
assign out.lor = (!i[29]&!i[27]&!i[25]&i[14]&i[13]&!i[12]&!i[6]&!i[2]) | (!i[6]&i[3]) | ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[verible-verilog-format] reported by reviewdog 🐶
assign out.lor = (!i[29]&!i[27]&!i[25]&i[14]&i[13]&!i[12]&!i[6]&!i[2]) | (!i[6]&i[3]) | ( | |
assign out.lor = (!i[29]&!i[27]&!i[25]&i[14]&i[13]&!i[12]&!i[6]&!i[2]) | (!i[6]&i[3]) | ( |
design/dec/el2_dec_decode_ctl.sv
Outdated
@@ -1624,7 +1623,7 @@ assign out.presync = (!i[5]&i[3]) | (!i[13]&i[7]&i[6]&i[4]) | (!i[13]&i[8]&i[6]& | |||
i[17]&i[13]&i[6]&i[4]) | (i[18]&i[13]&i[6]&i[4]) | (i[19]&i[13]&i[6] | |||
&i[4]); | |||
|
|||
assign out.postsync = (i[12]&!i[5]&i[3]) | (!i[22]&!i[13]&!i[12]&i[6]&i[4]) | ( | |||
assign out.postsync = (!i[22]&!i[13]&!i[12]&i[6]&i[4]) | (i[12]&!i[5]&i[3]) | ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[verible-verilog-format] reported by reviewdog 🐶
assign out.postsync = (!i[22]&!i[13]&!i[12]&i[6]&i[4]) | (i[12]&!i[5]&i[3]) | ( | |
assign out.postsync = (!i[22]&!i[13]&!i[12]&i[6]&i[4]) | (i[12]&!i[5]&i[3]) | ( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remaining comments which cannot be posted as a review comment to avoid GitHub Rate Limit
verible-verilog-format
design/dec/el2_dec_decode_ctl.sv|1661|
design/dec/el2_dec_decode_ctl.sv|1675|
design/dec/el2_dec_decode_ctl.sv|1677|
design/dec/el2_dec_decode_ctl.sv|1679|
design/dec/el2_dec_decode_ctl.sv|1681|
design/dec/el2_dec_decode_ctl.sv|1683|
design/dec/el2_dec_decode_ctl.sv|1685|
design/dec/el2_dec_decode_ctl.sv|1687|
design/dec/el2_dec_decode_ctl.sv|1698|
design/dec/el2_dec_decode_ctl.sv|1700|
design/dec/el2_dec_decode_ctl.sv|1702|
design/dec/el2_dec_decode_ctl.sv|1704|
design/dec/el2_dec_decode_ctl.sv|1711|
design/dec/el2_dec_decode_ctl.sv|1717|
design/dec/el2_dec_decode_ctl.sv|1719|
design/dec/el2_dec_decode_ctl.sv|1721|
design/dec/el2_dec_decode_ctl.sv|1723|
design/dec/el2_dec_decode_ctl.sv|1725|
design/dec/el2_dec_decode_ctl.sv|1727|
design/dec/el2_dec_decode_ctl.sv|1733|
design/dec/el2_dec_decode_ctl.sv|1735|
design/dec/el2_dec_decode_ctl.sv|1737|
design/dec/el2_dec_decode_ctl.sv|1762|
design/dec/el2_dec_decode_ctl.sv|1764|
design/dec/el2_dec_decode_ctl.sv|1769|
design/dec/el2_dec_decode_ctl.sv|1771|
design/dec/el2_dec_decode_ctl.sv|1773|
design/dec/el2_dec_decode_ctl.sv|1775|
design/dec/el2_dec_decode_ctl.sv
Outdated
// To generate instruction legality check equation do: | ||
// 1) coredecode -in decode -legal > legal.e | ||
// 2) espresso -Dso -oeqntott < legal.e | addassign -pre out. > legal | ||
// 3) copy-paste assignment from the file "legal" and replace the one below. | ||
|
||
module el2_dec_dec_ctl | ||
import el2_pkg::*; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[verible-verilog-format] reported by reviewdog 🐶
import el2_pkg::*; | |
import el2_pkg::*; |
design/dec/el2_dec_decode_ctl.sv
Outdated
input logic [31:0] inst, | ||
output el2_dec_pkt_t out |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[verible-verilog-format] reported by reviewdog 🐶
input logic [31:0] inst, | |
output el2_dec_pkt_t out | |
input logic [31:0] inst, | |
output el2_dec_pkt_t out |
design/dec/el2_dec_decode_ctl.sv
Outdated
!i[13]&i[9]&!i[2]) | (i[18]&i[13]&!i[2]) | (!i[13]&i[8]&!i[2]) | ( | ||
i[17]&i[13]&!i[2]) | (!i[13]&i[7]&!i[2]) | (i[16]&i[13]&!i[2]) | ( | ||
i[15]&i[13]&!i[2]) | (!i[4]&!i[2]) | (!i[14]&!i[13]&i[6]&!i[3]) | ( | ||
!i[6]&!i[2]); | ||
|
||
assign out.rs2 = (i[5]&!i[4]&!i[2]) | (!i[6]&i[5]&!i[2]); | ||
assign out.rs2 = (i[5]&!i[4]&!i[2]) | (!i[6]&i[5]&!i[2]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[verible-verilog-format] reported by reviewdog 🐶
assign out.rs2 = (i[5]&!i[4]&!i[2]) | (!i[6]&i[5]&!i[2]); | |
assign out.rs2 = (i[5] & !i[4] & !i[2]) | (!i[6] & i[5] & !i[2]); |
design/dec/el2_dec_decode_ctl.sv
Outdated
&i[6]&i[4]) | (!i[12]&!i[5]&i[4]&!i[2]); | ||
|
||
assign out.rd = (!i[5]&!i[2]) | (i[5]&i[2]) | (i[4]); | ||
assign out.rd = (!i[5]&!i[2]) | (i[5]&i[2]) | (i[4]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[verible-verilog-format] reported by reviewdog 🐶
assign out.rd = (!i[5]&!i[2]) | (i[5]&i[2]) | (i[4]); | |
assign out.rd = (!i[5] & !i[2]) | (i[5] & i[2]) | (i[4]); |
design/dec/el2_dec_decode_ctl.sv
Outdated
&!i[5]&i[4]&!i[2]) | (i[14]&!i[13]&i[12]&!i[5]&i[4]&!i[2]); | ||
|
||
assign out.imm20 = (i[5]&i[3]) | (i[4]&i[2]); | ||
assign out.imm20 = (i[5]&i[3]) | (i[4]&i[2]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[verible-verilog-format] reported by reviewdog 🐶
assign out.imm20 = (i[5]&i[3]) | (i[4]&i[2]); | |
assign out.imm20 = (i[5] & i[3]) | (i[4] & i[2]); |
design/dec/el2_dec_decode_ctl.sv
Outdated
!i[27]&i[25]&!i[14]&!i[13]&i[12]&!i[6]&i[4]&!i[2]); | ||
|
||
assign out.rs2_sign = (!i[27]&i[25]&!i[14]&!i[13]&i[12]&!i[6]&i[4]&!i[2]); | ||
assign out.rs2_sign = (!i[27]&i[25]&!i[14]&!i[13]&i[12]&!i[6]&i[4]&!i[2]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[verible-verilog-format] reported by reviewdog 🐶
assign out.rs2_sign = (!i[27]&i[25]&!i[14]&!i[13]&i[12]&!i[6]&i[4]&!i[2]); | |
assign out.rs2_sign = (!i[27] & i[25] & !i[14] & !i[13] & i[12] & !i[6] & i[4] & !i[2]); |
design/dec/el2_dec_decode_ctl.sv
Outdated
|
||
assign out.low = (i[25]&!i[14]&!i[13]&!i[12]&i[5]&i[4]&!i[2]); | ||
assign out.low = (i[25]&!i[14]&!i[13]&!i[12]&i[5]&i[4]&!i[2]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[verible-verilog-format] reported by reviewdog 🐶
assign out.low = (i[25]&!i[14]&!i[13]&!i[12]&i[5]&i[4]&!i[2]); | |
assign out.low = (i[25] & !i[14] & !i[13] & !i[12] & i[5] & i[4] & !i[2]); |
design/dec/el2_dec_decode_ctl.sv
Outdated
|
||
assign out.div = (!i[27]&i[25]&i[14]&!i[6]&i[5]&!i[2]); | ||
assign out.div = (!i[27]&i[25]&i[14]&!i[6]&i[5]&!i[2]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[verible-verilog-format] reported by reviewdog 🐶
assign out.div = (!i[27]&i[25]&i[14]&!i[6]&i[5]&!i[2]); | |
assign out.div = (!i[27] & i[25] & i[14] & !i[6] & i[5] & !i[2]); |
design/dec/el2_dec_decode_ctl.sv
Outdated
|
||
assign out.rem = (!i[27]&i[25]&i[14]&i[13]&!i[6]&i[5]&!i[2]); | ||
assign out.rem = (!i[27]&i[25]&i[14]&i[13]&!i[6]&i[5]&!i[2]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[verible-verilog-format] reported by reviewdog 🐶
assign out.rem = (!i[27]&i[25]&i[14]&i[13]&!i[6]&i[5]&!i[2]); | |
assign out.rem = (!i[27] & i[25] & i[14] & i[13] & !i[6] & i[5] & !i[2]); |
design/dec/el2_dec_decode_ctl.sv
Outdated
|
||
assign out.fence = (!i[5]&i[3]); | ||
assign out.fence = (!i[5]&i[3]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[verible-verilog-format] reported by reviewdog 🐶
assign out.fence = (!i[5]&i[3]); | |
assign out.fence = (!i[5] & i[3]); |
97b334d
to
d5f91a0
Compare
Internal-tag: [#51652] Signed-off-by: Maciej Kurc <[email protected]>
Internal-tag: [#51652] Signed-off-by: Maciej Kurc <[email protected]>
d5f91a0
to
0b0a4dd
Compare
Links to coverage and verification reports for this PR (#138) are available at https://chipsalliance.github.io/Cores-VeeR-EL2/ |
LGTM |
This PR updates the instruction decoder so that it does not treat
FENCE
/FENCE.I
with non-zero supplementary arguments as illegal. This behavior conforms to the spec in version "20190608-Base-Ratified" which VeeR is compatible with.With that PR I also updated the instructions on how to re-generate instruction decoder equations.
Solves #128